<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>use strict demo</title>
</head>
<style>
    div {
        border: aqua;
    }
</style>
<body>
<div id="a"></div>
<div id="b"></div>
<div id="c"></div>
<div id="e"></div>
</body>
<script>
    //"use strict"
    a = '111';
    // lib.dom.d.ts
    window.document.getElementById("a").innerHTML=a;
</script>
<!--
Uncaught SyntaxError: Cannot use import statement outside a module的解决方法
这里报错的原因是用了es6的语法， 浏览器默认将它作为js解析会出现问题，需要将它作为模块导入，
script标签默认type="text/javascript"，需要改为type="module"，更改后的index.html:
-->
<script type="module">
    import {sayHi} from "./say.js";
    sayHi('join')
</script>
</html>
